<?php
// TODO: pom    澳买拼团 逻辑处理
namespace Home\Common;

class Register
{
   
    // TODO: 获取 商品 详情要显示的数据
    public function getDetailDataForPieces($PiecesId)
    {
      $ret = array('123');


      return $ret;
    }


    // TODO: 获取列表要显示的数据
    public function getPiecesData()
    {
      // LibTools::fileDebug(,"");

      $ret = array();

      // for( $i = 0 ; $i < 11 ; $i ++ )
      // {
      //   $ret[$i]["pieces_default_img"] = "/attas/68_P_1446689224515.jpg";
      //   $ret[$i]["goods_default_imgs"] = array();
      //   for( $j = 0 ; $j< 3; $j++ )
      //   {
      //     $ret[$i]["goods_default_imgs"][$j] = "/themes/images/nopicture3.jpg";
      //   }
      //   $ret[$i]["name"]  = "Lucas papaw 神奇番木瓜膏 润唇膏/多功能万用膏 25g";
      //   $ret[$i]["price"] = 120;
      //   $ret[$i]["umpires"] = 5;
      //   $ret[$i]["limit_time"] = time() + 3*24*60*60;
      // }

      //TODO: 构造 51m类似的

      $ret[0]['num'] = 100;

      $ret[0]['flag'] = 1;
      $ret[0]['imgs'][0] = "/attas/68_P_1446689224515.jpg";
      $ret[0]['imgs'][1] = "/attas/68_G_1463454974181.jpg";

      $ret[0]['packagename'] = "Lucas papaw 神奇番木瓜膏 润唇膏/多功能万用膏 25g";
      $ret[0]['sprice'] = 100.01;
      $ret[0]['vprice'] = 100.03;
      $ret[0]['uprice'] = 100.02;
      $ret[0]['count'] = 2;

      $ret[0]['goods'][0]['goods_thumb'] = "/attas/68_G_1463454974181.jpg";
      $ret[0]['goods'][0]['goods_name'] = "神奇番木瓜";
      $ret[0]['goods'][0]['price'] = 10.01;
      $ret[0]['goods'][0]['number'] = 3;

      $ret[0]['goods'][1]['goods_thumb'] = "/attas/20160918100951_57ddf76fabb8b.jpg";
      $ret[0]['goods'][1]['goods_name'] = "神奇番木瓜";
      $ret[0]['goods'][1]['price'] = 10.01;
      $ret[0]['goods'][1]['number'] = 3;

      $ret[0]['goods'][2]['goods_thumb'] = "/attas/68_G_1463454974181.jpg";
      $ret[0]['goods'][2]['goods_name'] = "神奇番木瓜";
      $ret[0]['goods'][2]['price'] = 10.01;
      $ret[0]['goods'][2]['number'] = 3;

      $ret[0]['goods'][3]['goods_thumb'] = "/attas/20160918100951_57ddf76fabb8b.jpg";
      $ret[0]['goods'][3]['goods_name'] = "神奇番木瓜";
      $ret[0]['goods'][3]['price'] = 10.01;
      $ret[0]['goods'][3]['number'] = 3;

      $ret[0]['goods'][4]['goods_thumb'] = "/attas/68_G_1463454974181.jpg";
      $ret[0]['goods'][4]['goods_name'] = "神奇番木瓜";
      $ret[0]['goods'][4]['price'] = 10.01;
      $ret[0]['goods'][4]['number'] = 3;

      $ret[0]['goods'][5]['goods_thumb'] = "/attas/20160918100951_57ddf76fabb8b.jpg";
      $ret[0]['goods'][5]['goods_name'] = "神奇番木瓜";
      $ret[0]['goods'][5]['price'] = 10.01;
      $ret[0]['goods'][5]['number'] = 3;

      $ret[0]['blongtype'] = 'Group';
      $ret[0]['total'] = '5';

      $ret[0]['minnumber'] = 2;
      $ret[0]['maxnumber'] = 5;

      $d = strtotime("tomorrow");
      $ret[0]['endtime'] = date("Y/m/d h:i:s", $d);
      $ret[0]['packageid'] = '1000';

      // ------------

      $ret[1]['num'] = 100;

      $ret[1]['flag'] = 1;
      $ret[1]['imgs'][0] = "/attas/68_G_1463454974181.jpg";
      $ret[1]['packagename'] = "Tetley 泰特莱 纯绿茶 茶包 50包";
      $ret[1]['sprice'] = 100.01;
      $ret[1]['vprice'] = 100.03;
      $ret[1]['uprice'] = 100.02;
      $ret[1]['count'] = 2;

      $ret[1]['goods'][0]['goods_thumb'] = "/attas/68_P_1446689224515.jpg";
      $ret[1]['goods'][0]['goods_name'] = "神奇番木瓜";
      $ret[1]['goods'][0]['price'] = 10.01;
      $ret[1]['goods'][0]['number'] = 3;

      $ret[1]['goods'][1]['goods_thumb'] = "/attas/20160918100951_57ddf76fabb8b.jpg";
      $ret[1]['goods'][1]['goods_name'] = "神奇番木瓜";
      $ret[1]['goods'][1]['price'] = 10.01;
      $ret[1]['goods'][1]['number'] = 3;

      $ret[1]['blongtype'] = 'Group';
      $ret[1]['total'] = '5';

      $ret[1]['minnumber'] = 1;
      $ret[1]['maxnumber'] = 5;

      $d = strtotime("tomorrow");
      $ret[1]['endtime'] = date("Y/m/d h:i:s", $d);
      $ret[1]['packageid'] = '1001';
















      return $ret;
    }

















}






?>
